
cmake_minimum_required(VERSION 3.10.2)

project("ffmpeg54")

include_directories(include)
include_directories(soundtouch/include)
include_directories(soundtouch/SoundTouch)
#添加一个系统查找目录
#添加系统环境变量
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -L${CMAKE_SOURCE_DIR}/libs/${ANDROID_ABI}")

#同级目录包含"."的文件
aux_source_directory(. SOURCE)

aux_source_directory(./soundtouch/SoundTouch SOURCE_ST)

add_library(
        audio-native-lib
        SHARED


        #${SOURCE}=cpp下面文件
        ${SOURCE}
        ${SOURCE_ST}
#        audio-native-lib.cpp
#        MNAudio.cpp
#        MNCallJava.cpp
#        MNFFmpeg.cpp
        )


find_library(
        log-lib
        log)

target_link_libraries(
        audio-native-lib

        avcodec
        avdevice
        avfilter
        avformat
        avutil
        swresample
        swscale
        # Links the target library to the log library
        # included in the NDK.
        android
        OpenSLES
        ${log-lib})

